package com.ht.temp.mapper;

import com.ht.temp.entity.MinReport;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author mayke_zhou
 * @since 2018-12-24
 */
public interface MinReportMapper extends BaseMapper<MinReport> {

    //查询分报表某一小时之前一小时所有分的平均数据
    public List<MinReport> selectMinReportByHours(@Param("nowTime") String nowTime,@Param("afterTime") String afterTime,@Param("deviceId") Integer deviceId);

    //计算分报表某一小时之前一小时所有分的平均数据
    public MinReport selectMinReportByHoursAvg(@Param("nowTime") String nowTime,@Param("afterTime") String afterTime,@Param("deviceId") Integer deviceId);

    Integer insertMinReport(MinReport minReport);
}
